
class UserSqlMap(object):
    update_password = "update aoa_user set aoa_user.password='{password}' where user_id={user_id}"
    edit_message = "update aoa_user set "
    # edit_message = "update aoa_user set user_tel='{user_tel}',address='{address}' where user_id={user_id}"
    check_message = "select t1.age,t2.user_name,t2.real_name,t2.user_tel,t4.dept_name,t5.name as position_name,t1.jobnumber,t6.role_name,t2.sex,t2.user_school,t2.user_edu,t2.password,t2.address,t1.height,t1.weight,t1.is_marry,t1.household_classify,t1.join_army,t1.political_status,t1.nation,t1.have_chronic,t1.have_contagion,t1.join_ncms,t1.legal_record,t1.certificate,t1.profession,t3.status_name,t1.job_time,t1.regular_time,t1.domicile,t2.img_path from aoa_humanres as t1 inner join aoa_user as t2 on t1.user_id=t2.user_id inner join aoa_status_list as t3 on t1.status=t3.status_id inner join aoa_dept as t4 on t2.dept_id=t4.dept_id inner join aoa_position as t5 on t2.position_id=t5.position_id inner join aoa_role_ as t6 on t2.role_id=t6.role_id where t1.user_id={user_id}"

    CHECK_ATTACH = "select * from aoa_attachment_list where attachment_id={attach_id}"
    UPDATE_HUM = "update aoa_humanres set attachments={attach_id} where user_id={user_id}"